#pragma once

#include <list>
#include <string>
#include <vector>
using namespace std;

class clkXmlDocument;

struct clkXmlAttribute
{
	string m_name;
	string m_data;
};

class clkXmlElement
{
private:
	friend clkXmlDocument;

	string m_name;
	string m_data;
	clkXmlElement* m_parent;
	clkXmlElement* m_child;
	clkXmlElement* m_next;
	clkXmlElement* m_prev;
	vector<clkXmlAttribute*> m_attributes;
public:
	clkXmlElement();
	~clkXmlElement();

	clkXmlAttribute* getAttribute(string a_name);
	clkXmlElement* getChild(string a_name);
	string getAttributeData(string a_name);
	string getChildData(string a_name);
	vector<clkXmlElement*> getChildren(string a_name);

	string getName(){return m_name;}
	string getData(){return m_data;}
};